package com.gr.dmbackend.controller.sysadmin;

import com.alibaba.fastjson.JSONObject;
import com.gr.dmbackend.service.sysadmin.AddStudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

@RestController
public class AddStudentController {

    @Autowired
    private AddStudentService addStudentService;

    @PostMapping("/api/sysadmin/add-student")
    public JSONObject addStudent(@RequestParam Map<String, String> data) {
        return addStudentService.addStudent(data);
    }
}
